Collective Operations in a File System Based Execution Model

ABSTRACT

A mechanism is provided for group communications using a MULTI-PIPE synthetic file system. A master application creates a multi-pipe synthetic file in the MULTI-PIPE synthetic file system, the master application indicating a multi-pipe operation to be performed. The master application then writes a header-control block of the multi-pipe synthetic file specifying at least one of a multi-pipe synthetic file system name, a message type, a message size, a specific destination, or a specification of the multi-pipe operation. Any other application participating in the group communications then opens the same multi-pipe synthetic file. A MULTI-PIPE file system module then implements the multi-pipe operation as identified by the master application. The master application and the other applications then either read or write operation messages to the multi-pipe synthetic file and the MULTI-PIPE synthetic file system module performs appropriate actions.

This invention was made with United States Government support underContract No. DE-FG02-08ER25851 awarded by the United States Departmentof Energy. The Government has certain rights in this invention.

BACKGROUND

The present application relates generally to an improved data processingapparatus and method and more specifically to mechanisms for a filesystem interface for point-to-point and collective operations.

As computation moves to multi-core and, distributed computing systems,the traditional way of performing computations, i.e. isolated in asingle process on a single core, is increasingly anachronistic.Operating environments for modern “cloud” systems must handle twodifferent, but increasingly similar, execution environments: multi-corecentral processing units (CPUs) and distributed computing systems basedon commodity hardware. The challenge in these loosely couple, massivelyparallel computing systems is to coordinate workloads and providecommunication to maximize the utilization of the hardware.

The inability to maximize the workload has lead to dataflow computingsystems, both in the applications and in middleware. These computingsystems, built on top of commodity systems, create distributed modelsfor fault tolerance and the distribution of computation. However, sincethis middleware is not tightly integrated with their underlying systems,current development has moved to an entirely new world: new languages,new runtimes, and another level of abstraction on top of traditionalcomputing systems. Taking a middleware approach, while powerful, bothconstrains and abandons many computing system design principles thatmake programs portable, usable and responsive.

Furthermore, existing tools cannot be easily transferred or used inconjunction with each other. These new computing systems require thatyou implement new modules in whatever specific language the middlewareuses (typically C++ or Java), wrap sequential code, interact throughruntime specific languages, or make use of language bindings. This hasled to the constant reimplementation of well understood tools to workwithin these frameworks, which is not always practical for many largeapplication bases. Constantly re-solving the same problems for each, newrun-time.

SUMMARY

In one illustrative embodiment, a method, in a data processing system,is provided for group communications using a MULTI-PIPE synthetic filesystem. The illustrative embodiment creates a multi-pipe synthetic filein a plurality of multi-pipe synthetic files in the MULTI-PIPE syntheticfile system. In the illustrative embodiment, a master applicationindicates a multi-pipe operation to be performed by writing aheader-control block to a multi-pipe synthetic file using a specificoffset. In the illustrative embodiment, the header-control blockspecifies at least one of a multi-pipe synthetic file system name, amessage type, a message size, a specific destination, or a specificationof the multi-pipe operation. The illustrative embodiment opens themulti-pipe synthetic file in the MULTI-PIPE synthetic file system usingat least one other application in the plurality of applicationsparticipating in group communications. The illustrative embodimentsignals a MULTI-PIPE file system module in an operating system of themulti-pipe operation using the MULTI-PIPE synthetic file system. Theillustrative embodiment then implements the multi-pipe operation asidentified by the master application using the MULTI-PIPE file systemmodule. In the illustrative embodiment, the master application and theat least one other application in the group communication either read orwrite operation messages to the multi-pipe synthetic file. In theillustrative embodiment, the messages are signaled to the MULTI-PIPEfiles system module and the MULTI-PIPE synthetic file system moduleperforms an appropriate action based on the mode identified by themaster application.

In other illustrative embodiments, a computer program product comprisinga computer useable or readable medium having a computer readable programis provided. The computer readable program, when executed on a computingdevice, causes the computing device to perform various ones, andcombinations of, the operations outlined above with regard to the methodillustrative embodiment.

In yet another illustrative embodiment, a system/apparatus is provided.The system/apparatus may comprise one or more processors and a memorycoupled to the one or more processors. The memory may compriseinstructions which, when executed by the one or more processors, causethe one or more processors to perform various ones, and combinations of,the operations outlined above with regard to the method illustrativeembodiment.

These and other features and advantages of the present invention will bedescribed in, or will become apparent to those of ordinary skill in theart in view of, the following detailed description of the exampleembodiments of the present invention.

BRIEF DESCRIPTION OF THE SEVERAL VIEWS OF THE DRAWINGS

The invention, as well as a preferred mode of use and further objectivesand advantages thereof, will best be understood by reference to thefollowing detailed description of illustrative embodiments when read inconjunction with the accompanying drawings, wherein:

FIG. 1 depicts a pictorial representation of an example distributed dataprocessing system in which aspects of the illustrative embodiments maybe implemented;

FIG. 2 shows a block diagram of an example data processing system inwhich aspects of the illustrative embodiments may be implemented;

FIG. 3 depicts a block diagram of a file system interface forpoint-to-point and collective operations in accordance with anillustrative embodiment; and

FIG. 4 depicts a high level operation performed in a data processingsystem for group communications using a MULTI-PIPE, synthetic filesystem in accordance with an illustrative embodiment.

DETAILED DESCRIPTION

The illustrative embodiments provide a mechanism for a file systeminterface for point-to-point and collective operations. The illustrativeembodiments provide a multi-pipe mechanism which builds upon thefamiliar syntax of pipes but provides features and functions to bettersupport emerging scale-out computing environments and applications. Theterm pipe refers to the way applications are hooked together in order tocommunicate and cooperate. Similar to a pipe, the illustrativeembodiments are accessed purely through the file system namespace usingonly pre-existing file system operations. In order to accomplish this,the illustrative embodiments build the mechanism as a synthetic filesystem, one which does not use any backing storage like a typical filesystem.

Thus, the illustrative embodiments may be utilized in many differenttypes of data processing environments including a distributed dataprocessing, environment (through the use of established distributedresource protocols and distributed file systems), a single dataprocessing device, or the like. In order to provide a context for thedescription of the specific elements and functionality of theillustrative embodiments, FIGS. 1 and 2 are provided hereafter asexample environments in which aspects of the illustrative embodimentsmay be implemented. While the description following FIGS. 1 and 2 willfocus primarily on a single data processing device implementation of afile system interface for point-to-point and collective communications,this is only an example and is not intended to state or imply, anylimitation with regard to the features of the present invention. To thecontrary, the illustrative embodiments are intended to includedistributed data processing environments and embodiments in whichpoint-to-point and collective communications may be implemented in afile system interface.

With reference now to the figures and in particular with reference toFIGS. 1-2, example diagrams of data processing environments are providedin which illustrative embodiments of the present invention may beimplemented. It should be appreciated that FIGS. 1-2 are only examplesand are not intended to assert or imply any limitation with regard tothe environments in which aspects or embodiments of the presentinvention may be implemented. Many modifications to the depictedenvironments may be made without departing from the spirit and scope ofthe present invention.

With reference now to the figures, FIG. 1 depicts a pictorialrepresentation of an example distributed data processing system in whichaspects of the illustrative embodiments may be implemented. Distributeddata processing system 100 may include a network of computers in whichaspects of the illustrative embodiments may be implemented. Thedistributed data processing system 100 contains at least one network102, which is the medium used to provide communication links betweenvarious devices and computers connected together within distributed dataprocessing system 100. The network 102 may include connections, such aswire, wireless communication links, or fiber optic cables.

In the depicted example, server 104 and server 106 are connected tonetwork 102 along with storage unit 108. In addition, clients 110, 112,and 114 are also connected to network 102. These clients 110, 112, and114 may be, for example, personal computers, network computers, or thelike. In the depicted example, server 104 provides data, such as bootfiles, operating system images, and applications to the clients 110,112, and 114. Clients 110, 112, and 114 are clients to server 104 in thedepicted example. Distributed data processing system 100 may includeadditional servers, clients, and other devices not shown.

In the depicted example, distributed data processing system 100 is the.Internet with network 102 representing a worldwide collection ofnetworks and gateways that use the Transmission ControlProtocol/Internet Protocol (TCP/IP) suite of protocols to communicatewith one another. At the heart of the Internet is a backbone ofhigh-speed data communication lines between major nodes or hostcomputers, consisting of thousands of commercial, governmental,educational and other computer systems that route data and messages. Ofcourse, the distributed data processing system 100 may also beimplemented to include a number of different types of networks, such asfor example, an intranet, a local area network (LAN), a wide areanetwork (WAN), or the like. As stated above, FIG. 1 is intended as anexample, not as an architectural limitation for different embodiments ofthe present invention, and therefore, the particular elements shown inFIG. 1 should not be considered limiting with regard to the environmentsin which the illustrative embodiments of the present invention may beimplemented.

With reference now to FIG. 2, a block diagram of an example dataprocessing system is shown in which aspects of the illustrativeembodiments may be implemented. Data processing system 200 is an exampleof a computer, such as client 110 in FIG. 1, in which computer usablecode or instructions implementing the processes for illustrativeembodiments of the present invention may be located.

In the depicted example, data processing system 200 employs a hubarchitecture including north bridge and memory controller hub (NB/MCH)202 and south bridge and input/output (I/O) controller hub (SB/ICH) 204.Processing unit 206, main memory 208, and graphics processor 210 areconnected to NB/MCH 202. Graphics processor 210 may be connected toNB/MCH 202 through an accelerated graphics port (AGP).

In the depicted example, local area network (LAN) adapter 212 connectsto SB/ICH 204. Audio adapter 216, keyboard and mouse adapter 220, modem222, read only memory (ROM) 224, hard disk drive (HDD) 226, CD-ROM drive230, universal serial bus (USB) ports and other communication ports 232,and PCI/PCIe devices 234 connect to SB/ICH 204 through bus 238 and bus240. PCI/PCIe devices may include, for example, Ethernet adapters,add-in cards, and PC cards for notebook computers. PCI uses a card buscontroller, while PCIe does not. ROM 224 may be, for example, a flashbasic input/output system (BIOS).

HDD 226 and CD-ROM drive 230 connect to SB/ICH 204 through bus 240. HDD226 and CD-ROM drive 230 may use, for example, an integrated driveelectronics (IDE) or serial advanced technology attachment (SATA)interface. Super I/O (SIO) device 236 may be connected to SB/ICH 204.

An operating system runs on processing unit 206. The operating systemcoordinates and provides control of various components within the dataprocessing system 200 in FIG. 2. As a client, the operating system maybe a commercially available operating system such as Microsoft® Windows®XP (Microsoft and Windows are trademarks of Microsoft Corporation in theUnited States, other countries, or both). An object-oriented programmingsystem, such as the Java™ programming system, may run in conjunctionwith the operating system and provides calls to the operating systemfrom Java™ programs or applications executing on data processing system200 (Java is a trademark of Sun Microsystems, Inc. in the United States,other countries, or both).

As a server, data processing system 200 may be, for example, an IBM®eServer™ System p® computer system; running the Advanced InteractiveExecutive (AIX®) operating system or the LINUX® operating system(eServer, System p, and AIX are trademarks of International BusinessMachines Corporation in the United States, other countries, or bothwhile LINUX is a trademark of Linus Torvalds in the United States, othercountries, or both). Data processing system 200 may be a symmetricmultiprocessor (SMP) system including a plurality of processors inprocessing unit 206. Alternatively, a single processor system may beemployed.

Instructions for the operating system, the object-oriented programmingsystem, and applications or programs are located on storage devices,such as HDD 226, and may be loaded into main memory 208 for execution byprocessing unit 206. The processes for illustrative embodiments of thepresent invention may be performed by processing unit 206 using computerusable program code, which may be located in a memory such as, forexample, main memory 208, ROM 224, or in one or more peripheral devices226 and 230, for example.

A bus system, such as bus 238 or bus 240 as shown in FIG. 2, may becomprised of one or more buses. Of course, the bus system may beimplemented using any type of communication fabric or architecture thatprovides for a transfer of data between different components or devicesattached to the fabric or architecture. A communication unit, such asmodem 222 or network adapter 212 of FIG. 2, may include one or moredevices used to transmit and receive data. A memory may be, for example,main memory 208, ROM 224, or a cache such as found in. NB/MCH 202 inFIG. 2.

Those of ordinary skill in the art will appreciate that the hardware inFIGS. 1-2 may vary depending on the implementation. Other internalhardware or peripheral devices, such as flash memory, equivalentnon-volatile memory, or optical disk drives and the like, may be used inaddition to or in place of the hardware depicted in FIGS. 1-2. Also, theprocesses of the illustrative embodiments may be applied to amultiprocessor data processing system, other than the SMP systemmentioned previously, without departing from the spirit and scope of thepresent invention.

Moreover, the data processing system 200 may take the form of any of anumber of different data processing systems including client computingdevices, server computing devices, a tablet computer, laptop computer,telephone or other communication device, a personal digital assistant(PDA), or the like. In some illustrative examples, data processingsystem 200 may be a portable computing device which is configured withflash memory to provide non-volatile memory for storing operating systemfiles and/or user-generated data, for example. Essentially, dataprocessing system 200 may be any known or later developed dataprocessing system without architectural limitation.

Again, the illustrative embodiments provide a multi-pipe mechanism whichbuilds upon the familiar syntax of pipes but provides features andfunctions to better support emerging scale-out computing environmentsand applications. Similar to a pipe, the mechanism may be primarilyaccessed purely through the file system namespace using onlypre-existing file system operations. In order to accomplish this, themechanism is implemented as a synthetic file system that does not useany backing storage like a typical file system.

FIG. 3 depicts a block diagram of a file system interface forpoint-to-point and collective operations in accordance with anillustrative embodiment. Data processing system 300 comprises operatingsystem 302, applications 304, and file system namespace 306. File systemnamespace 306 provides a uniform interface to applications 304. Underthe hood of this uniform interface, file system namespace 306 includesother file systems, including synthetic file systems. In FIG. 3, theentries DEV, PROC, and MULTI-PIPE are synthetic file systems 308 whosefunctionalities are provided by MULTI-PIPE file system module 310,PROC-FS module 312, and DEV-FS module 314, respectively. Applications304 interact with file system namespace 306, and depending on whichdirectories an application in applications 304 is interacting with, acorresponding file system module 310-316 in operating system 302 handlesthese requests of the application. For example, any interaction by anapplication within MULTI-PIPE synthetic file system 320 will be handledby MULTI-PIPE file system module 310. That is, MULTI-PIPE file systemmodule 310 may be used by any application in applications 304 bymounting one of multi-pipe synthetic files 321 in file system namespace306. As opposed to file systems that are purely part of an operatingsystem, MULTI-PIPE file system module 310 may be implemented as userspace file servers, may be embedded within the operating system itselfas built-in file systems, or may be a set of dynamically loaded modules.

MULTI-PIPE synthetic file system 320 may he constructed to allowallocation of new instances of multi-pipe synthetic files 321 via useraction, either by leveraging existing file-system interfaces, such asusing a ‘create’ system call with a path within the synthetic filehierarchy of MULTI-PIPE synthetic file system 320, or by using asynthetic control file which applications 304 may send commands to inorder to allocate new instances of multi-pipe synthetic files 321. Whilefile system namespace 306 may comprise files/directories for operationssuch as home, var, lib, mnt, dev, proc, or the like, the illustrativeembodiments are directed to a new type of synthetic file, namelymulti-pipe. Multi-pipes are communication channels that provide a hookbetween applications or processes of applications 304. MULTI-PIPEsynthetic file system 320 may also be constructed such that applications304 may mount one or more of multi-pipe operations represented bymulti-pipe synthetic files 321 by opening one or more multi-pipes usingmount options to MULTI-PIPE synthetic file system 320 that allowspecification of parameters for a particular multi-pipe instance foreach multi-pipe opened to the one or more of multi-pipe synthetic files321. If the mount option is not used, applications 304 may useparameters to MULTI-PIPE synthetic file system 320 that may be set via aheader-control block (discussed in detail below).

Each particular multi-pipe instance opened by applications 304 may berepresented within the synthetic file hierarchy of MULTI-PIPE syntheticfile system 320 as a single file, whose name is established as aparameter by either a create operation, a mount operation, acontrol-file write operation, or the like. Besides the, name,applications 304 may also associate a preset type with each particularmulti-pipe which establishes behavior on certain collective operations.A collective operation is an operation that requires a subset of allprocesses participating in a parallel job to wait for a result whosevalue depends on one or more input values provided by each of theparticipating processes. Typically, collectives are implemented by allprocesses within a communicator group calling the same collectivecommunication function with matching arguments. Essentially, acollective operation is an operation that is performed on each member ofa collective, e.g., each processor unit in a collective of processorunits, using the same controls, i.e. arguments. Some examples ofcollective operations supported by multi-pipe include broadcast, reduce,splice, barrier, allreduce, enumerated, or the like.

Since normal file system operations may be used as the interface toMULTI-PIPE synthetic file system 320, distributed access to MULTI-PIPEsynthetic file system 320 may be provided by a standard distributed filesystem protocol such as the 9P distributed resource protocol, networkfile sharing (NFS), Andrew file sharing (AFS), remote file sharing(RFS), or the like. Applications 304 may use a standard distributed filesystem protocol that allows the use of the file system namespace as anorganization principle with standard file system controls on accesscontrols and operation permissions and also allows applications 304using the file system interface of MULTI-PIPE synthetic file system 320to operate in a similar fashion on local and remote instances of thesynthetic file system interface.

Multi-pipe operations within the hierarchy of MULTI-PIPE synthetic filesystem 320 are reflected by MULTI-PIPE file system module 310 toMULTI-PIPE synthetic file system 320. MULTI-PIPE synthetic file system.320 uses the file hierarchy to track each open of its interfaces formulti-pipes and associate the open with a particular application inapplications 304 and also track whether the application 304 has openedthe multi-pipe as a reader or writer. Similar to opening a multi-pipe,when all writers of a multi-pipe close, MULTI-PIPE synthetic file system320 marks the multi-pipe as hungup and any subsequent readers of aparticular multi-pipe file receive an EOF from MULTI-PIPE synthetic filesystem 320. When all readers and writers close, MULTI-PIPE syntheticfile system 320 resets the multi-pipe so that the multi-pipe may bereused. When MULTI-PIPE synthetic file system 320 resets a multi-pipe,any special flags, such as broadcasts, enumerations, reduces, or thelike, will persist.

For normal read and write operations, MULTI-PIPE synthetic file system320 may operate identical to known pipe usage, except that themulti-pipe utilization of the illustrative embodiments areunidirectional and only a single synthetic file is provided permulti-pipe instance. That is, the multi-pipes of the illustrativeembodiments arc unidirectional because an application, which may also bereferred to as a process, may open a multi-pipe in only one mode, eitherread Mode or write mode. This makes the MULTI-PIPE unidirectional fromthe perspective of the application. Thus, in this mode the applicationmay either read or write the multi-pipe instance but not both. If twoapplications want bi-directional communication, then two multi-pipeswill be used, one multi-pipe for read and another multi-pipe for write.Also, there isn't any implicit buffering by the multi-pipes that areopened to MULTI-PIPE synthetic file system 320, so multi-pipe syntheticfiles 321, operating in a write mode, will block until an operationcompletes, for example, until multi-pipe synthetic files 321 pass allwritten data to all appropriate receivers or participants, i.e. otherapplications or processes employed to execute the current operation.

In addition to normal reads and writes, applications 304 may injectheader-control blocks into a multi-pipe, which may either act as controlmessages or describes the data following the header. Since themulti-pipes of the illustrative embodiments are not expected to honortraditional file system operation offsets, a master application inapplications 304, which may be referred to as initiators, and/or otherapplications in applications 304, which may be referred to asparticipants or sub-processes, may mark header-control block in thepackets being sent by writing at offset (ulong)˜0, −1, or the like.(ulong)˜0 refers to the largest possible value which may fit in aparticular memory location, “˜” is bitwise complement operator and “˜0”represents complement of the value zero, i.e. a value with all bits one.In unsigned number notation, value with all bits one is the largestpossible value. In the illustrative embodiments, (ulong)˜0 signifies aspecial offset value.

Offsets as used in traditional file systems, such as files on a disk,are used to read the data from a particular location. But in case oftraditional pipes, data is not stored on persistent storage and the readoperation on pipe is destructive, i.e. data, is destroyed once the datais read. Because of destructive reads, traditional pipes do not allow aread from any location, all reads are always performed at the beginningof the data, i.e. offset of zero. Because of this, operations ontraditional pipes will ignore the value of offset and always use zero asoffset. However, in the illustrative embodiments, MULTI-PIPE file systemmodule 310 makes use of the provided offset value in special way. If theoffset is zero, then MULTI-PIPE file system module 310 will treat thatoperation as a normal data operation. But if the offset is some fixedunique value, then MULTI-PIPE file system module 310 understands thatapplication is trying to send special control message, and MULTI-PIPEfile system module 310 will handle this request in special way based onthe content of the special control message. That is, applications 304are able to send more information to MULTI-PIPE file system module 310without breaking existing system-calls infrastructure.

Again, since the multi-pipes of the illustrative embodiments are notexpected to honor traditional file system operation offsets, only themaster application may set the type of the multi-pipe synthetic file.Any other applications used in the group communications may only useheader-control blocks. Thus, a master application or process owns themulti-pipe and that master application or process is super-user for thatmulti-pipe. All other participating applications or processes may onlyperform normal operations. The illustrative embodiments implement thisrestriction so that control messages that are used to change thebehavior of the multi-pipe and hence the illustrative embodiments do notwant any participating, application and process changing the behavior ofthe multi-pipe simultaneously. Thus, the fields of the header-controlblock, in order, are:

-   -   a. type—header type (single byte)    -   b. size—size of message (in bytes)    -   c. enum—destination pipe enumeration (numeric)    -   d. param—parameter string, which may include:        -   i. name for multi-pipe id initialization        -   ii. destination path for splice operations        -   iii. equation for reduction    -   *Not all fields are used by all header types.

A master application or process may instruct a multi-pipe to behave in aspecific manner by passing a packet to synthetic file 321 with anencoded header-control block that specifies at least one of a messagetype, a message size, a specification of a control packet, or aspecification of the multi-pipe operation by writing to a specificoffset. For example, a broadcast packet informs multi-pipe syntheticfile 321 to behave as broadcast medium. The following is a partialexample of the packets that may be supported by MULTI-PIPE file systemmodule 310, for example:

-   -   a. ‘n’—changes/sets the name of the multi-pipe    -   b. ‘p’—specifies a packet which can be used for long messages or        enumerated pipes    -   c. ‘b’—same as ‘p’ but specifies the packet should be broadcast        to all current readers    -   e. ‘E’—specifies that his pipe is enumerated and gives the        maximum enumeration    -   f. ‘B’—specifies that all messages on this pipe should be        broadcast    -   g. ‘+’—specifies that this pipe should be treated as a reduction        operation    -   h. ‘o’—specifies an open barrier operation    -   i. ‘r’—specifies a read barrier operation    -   j. ‘w’—specifies a write barrier operation    -   k. ‘c’—specifies a close barrier    -   l. ‘0’—clears pipe type (such as ‘B’, ‘E’, ‘+’, ‘o’, ‘r’, ‘w’,        c’,)    -   m. ‘>’—specifics a splice to control block    -   n. ‘<’—specifics a splice from control block

Thus, as opposed to known systems where parallel programming operationsare implemented either in the kernel or in middleware which isspecifically tied to the operating system that is being implemented andboth constrains and abandons many computing system design principlesthat make programs portable, usable, and responsive, the illustrativeembodiments provide MULTI-PIPE synthetic file system 320 which ispresented as an interface to applications 304 for implementation byoperating system 302. That is, MULTI-PIPE synthetic file system 320 isnot operating system specific and may be mounted by any type ofoperating system where parallel programming operations are required.

At a high level, when a master application in applications 304 requiresa mechanism for group communication, then the master application createsa multi-pipe synthetic file in multi-pipe synthetic files 321 withinMULTI-PIPE synthetic file system 320. The master application then writesa header-control block to multi-pipe synthetic file in MULTI-PIPEsynthetic file system 320 indicating how the multi-pipe synthetic fileshould perform and any restrictions for the other applications employedin the group communication. Once the master application sends thecontrol message, other applications that are participating in the groupcommunication open the same multi-pipe synthetic file within MULTI-PIPEsynthetic files system 320 and then communication can start. Each of theother applications opens the same multi-pipe synthetic file 321 in theMULTI-PIPE synthetic file system 320, each multi-pipe limited to onlybeing used in the mode directed by the master application and is notable to send any control messages. MULTI-PIPE synthetic file system 320then signals MULTI-PIPE file system module 310 in operating system 302of the requested multi-pipe operation and MULTI-PIPE file system module310 implements the multi-pipe operation as identified by the request.The mode that the other applications open the multi-pipe synthetic filein is dependent on the multi-pipe operation requested by the masterapplication.

In order to provide examples of how the illustrative embodiments mayhandle different multi-pipe operations, the illustrative embodimentsprovide the following examples.

MULTI-PIPE have two types of implicit operations, determined by virtueof the number of applications 304 which have them open for reading orwriting. When there is one writer and multiple readers, the MULTI-PIPEis said to be a fan out operation. When there is multiple writers and asingle reader, the MULTI-PIPE is said to be a fan in operation.

In a fan out operation, the master application in applications 304 opensthe initial multi-pipe in a write mode. The master application theninitializes the one or more other applications in applications 304required for the group communication. Since this is a fan out operation,each of the other applications opens the same multi-pipe insideMULTI-PIPE synthetic file system 320 in a read mode. Multi-pipe filesystem module 310 then receives the write message from the masterapplication on the multi-pipe opened in the write mode that is to befanned out to the other applications. MULTI-PIPE file system module 310blocks the writing master application in applications 304, and when anyof the other applications perform the read operation on this multi-pipe,MULTI-PIPE file system module 310 delivers the message to the otherapplication and unblocks the writing master application in applications304. This way, the messages generated by the master applications aredistributed between other applications depending on the order in whichthey read.

In a fan in operation, which is complimentary to the fan out operation,the master application in applications 304 opens the initial multi-pipein READ mode. The master application then initializes the one or moreother applications in applications 304 required for the groupcommunication. Since this is a fan in operation, each of the otherapplications opens the same multi-pipe synthetic files 321 in syntheticfile system 320 in a write mode. Multi-pipe file system module 310 thenreceives the write message from the other applications on the samemulti-pipe opened in a write mode. MULTI-PIPE file system module 310takes written data and blocks the writer until it has been read by themaster application.

Thus, the underlying mechanism of multiple pipes of the illustrativeembodiments support both fan out and fan in operations as well as thecase of when there are many readers and many writers. Thus, thedifferent readers and writers are isolated from one another byMULTI-PIPE synthetic file system 320 enabling application appropriatemultiplexing without the limitations of native file system I/Omultiplexing of operating system 302. Similar to normal pipes, innon-enumerated multi-pipe synthetic files 321, individual applicationsreading a specific multi-pipe synthetic file receive complete messagesin a round robin fashion from the master application without fragmentmessage intermixing.

However, on traditional pipes this multiplexing is limited by theunderlying atomic input/output (I/O) capabilities of the operationsystem which limit the size of data which can be written in a singlesystem call. The illustrative embodiments overcome this limitation byhaving the master application implement long messages as a component ofthe header-control block. Long messages, those intended for a singlereader sub-process, but with a size greater than the atomic I/O buffersize capable from multi-pipe synthetic files 321, may be accommodated byusing a header-control block with the size field specifying the totalsize of the message. The master application will be linked to aparticular reader application/sub-process until that many bytes havebeen sent as data messages. Thus, the master applications delivers thelong message as a contiguous unit to a specific readerapplication/sub-process.

Another limitation of traditional pipes is there is no way to directmessages to a particular application/sub-process. This is very useful inthe context of map/reduce type operations where the desire is todistribute writes with similar hash signatures to a particular readerapplication/sub-processes. The illustrative embodiments add the idea ofenumerated multi-pipes which are a variant of fan-out pipes which allowthe master application being the writer to specify a designated readersub-process for any particular message (including long messages asmentioned above). The only effective way to use enumerated pipes is tospecify the number of reader sub-processes enumerations as part of theinstance specification for the multi-pipe, or using an ‘E’ control blockas discussed previously. By specifying enumerations as part of theinstance specification for the multi-pipe, the master applicationcreates the specified number of slots for enumerations as part of thepipes. New reader application/sub-processes will be assigned round-robinto these slots as they open their individual multi-pipe. That is, anapplication writing a message with a header-control block is directed toa specific enumerated reader queue where it will be received by aspecific application when read from the multi-pipe file. An attempt toback fill reader application/sub-processes to under-populated slots ismade in order to balance the reader application/sub-processes among theavailable slots and allow new reader application/sub-processes to fillin gaps left by old reader application/sub-processes. If a readerapplication/sub-process for a particular enumeration is not yetavailable, then the master application, being the writer, will block.

In a splicing operation, the master application in applications 304links the created multi-pipes associated with each of the various tasksbeing performed with the sub-processes together of tethers themulti-pipes associated with each of the various tasks being performed bythe sub-processes to normal pipes or even to normal files provided byoperating system 302. Normal pipes are used to collect the outputgenerated by one process or application and feed it as the input toanother process or application. Unfortunately, use of normal pipesallows for the feed for input of one process or application with outputof only'one other process or application, creating a one-to-one mapping.Splicing allows for collection of output from many processes orapplications and as a feed to a single process or application. Hence,splicing creates one-to-many mappings. The splice from splice controlmessage from the master application will start a thread which will actas a writer, reading new data from the target path specified in theheader-control block. Either thread will exit on receiving EOF or anerror from their target. Neither currently makes use of the size orwhich field in the header-control block.

Broadcast operations are specialized fan-out operations which provide acopy of the message to each active reader. In a broadcast operation, themaster application or process in applications 304 opens an initialmulti-pipe synthetic files 321 in write mode to MULTI-PIPE syntheticfile system 320. The master application then writes the broadcastcontrol message to set the type of the multi-pipe into broadcast usingthe header-control block. The other applications or sub-processesindividually open the same multi-pipe synthetic files 321 in a readmode. By the master application writing the broadcast control message tomulti-pipe synthetic files 321, the master application triggerssynthetic file system 320 to signal MULTI-PIPE file system module 310 inoperating system 302 of the requested multi-pipe broadcast operation,which is then mounted by MULTI-PIPE file system module 310. The otherapplications issue a read request, which is blocked by MULTI-PIPE filesystem module 310 until the master application, which is the writer,writes a broadcast message. Once the master application writes thebroadcast message into the multi-pipe, MULTI-PIPE file system module 310unblocks all of the other applications and MULTI-PIPE file system module310 returns their read call with the same message written by the masterapplication. At this point, all of the other applications closemulti-pipe and the master application either closes the initialmulti-pipe or resets the initial multi-pipe for a different operation.

Barrier operations are a useful during collective communication toensure a consistent system state, in particular with respect to thenumber of active participants and sometimes more specifically to thenumber of active readers or writers. In a barrier operation, the masterapplication or process in applications 304 opens an initial multi-pipesynthetic file 321 in write mode to MULTI-PIPE synthetic file system320. The master application then writes a barrier control message to setthe type of the multi-pipe into barrier and specify the exact number ofparticipants for the barrier operation in the enumeration field. Forexample, assuming that the barrier operation is on the specific numberof the open operations. MULTI-PIPE synthetic file system 320 thensignals MULTI-PIPE file system module 310 in operating system 302 of therequested multi-pipe barrier operation, which MULTI-PIPE file systemmodule 310 blocks. Other applications start opening the same multi-pipesynthetic file 321 in the required mode. MULTI-PIPE file system module310 blocks all these open operations. Once the number of open calls onthe multi-pipe synthetic file 321 matches the number, specified inbarrier condition, MULTI-PIPE file system module 310 returns all of theopen calls. Also, MULTI-PIPE file system module 310 returns a specialcontrol message write request to create the barrier from the masterapplication at the same time.

Reduce operations are a specialized form of fan-in operations which alsoperform an operation (or set of operations) on the values being receivedfrom the other applications and return a single value on the masterapplication which initiated the reduce operation. In a reduce operation,the master application or process in applications 304 opens an initialmulti-pipe synthetic file 321 in write mode in MULTI-PIPE synthetic filesystem 320. The master application then writes the reduce controlmessage to set the type of the multi-pipe into reduce. Otherapplications then open the same multi-pipe in a write mode. MULTI-PIPEsynthetic file system 320 then signals MULTI-PIPE file system module 310in operating system 302 of the requested multi-pipe reduce operation.

At this point the master application opens the same multi-pipe again inread mode so that the final reduced value will be read by the masterapplication. The master application then issues a read request which isblocked by MULTI-PIPE file system module 310 until all of the values ofthe write operations are received from the other applications and therequested reduce operation is performed. The sort of operationssupported for reduction are implementation dependent, but commonoperations, such as accumulate, average, or the like, are supported aswell as message passing interface (MPI) style operations, such as SUM,MAX, MIN, PROD, LAND, BAND, LOR, BOR, LXOR, BXOR, MINLOC, MAXLOC, or thelike. While in most cases the values written by the other applicationswill be interpreted as values as opposed to strings, the illustrativeembodiments recognize that options may be provided to specify the typesof the values, such as integers, floats, double precision numbers, orthe like.

Once MULTI-PIPE file system module 310 receives the written values fromthe other applications, MULTI-PIPE file system module 310 performs therequested reduce operation, unblocks the master application and returnsthe read call of the master application with the result of the reduceoperation. At this point, all of the other applications close multi-pipeand the master application either closes the initial multi-pipe orresets the initial multi-pipe for a different operation.

Allreduce is a specialized form of reduce in which all of the otherapplications receive a copy of the result of the reduce operation fromMULTI-PIPE file system module 310. That is, once each of the otherapplications writes their values to MULTI-PIPE file system module 310,the other application opens the same multi-pipe synthetic file 321 againin the read mode so that the final reduced value may be read. Once themulti-pipe synthetic file 321 is opened in read mode for the otherapplication, the other application issues a read request which isblocked by MULTI-PIPE file system module 310 until all of the values ofthe write operations arc received from the other applications and therequested reduce operation is performed. Once MULTI-PIPE file systemmodule 310 receives the written values from the other applications,MULTI-PIPE file system module 310 performs the requested reduceoperation, unblocks the master application and the other applicationsand returns the read call of the master application and the otherapplications with the result of the reduce operation.

As will be appreciated by one skilled in the art, the present inventionmay be embodied as a system, method, or computer program product.Accordingly, aspects of the present invention may take the form of anentirely hardware embodiment, an entirely software embodiment (includingfirmware, resident software, micro-code, etc.) or an embodimentcombining software and hardware aspects that may all generally bereferred to herein as a “circuit,” “module” or “system.” Furthermore,aspects of the present invention may take the form of a computer programproduct embodied in any one or more computer readable medium(s) havingcomputer usable program code embodied thereon.

Any combination of one or more computer readable medium(s) may beutilized. The computer readable medium may be a computer readable signalmedium or a computer readable storage medium. A computer readablestorage medium may be, for example, but not limited to, an electronic,magnetic, optical, electromagnetic, infrared, or semiconductor system,apparatus, device, many suitable combination of the foregoing. Morespecific examples (a non-exhaustive list) of the computer readablemedium would include the following: an electrical connection having oneor more wires, a portable computer diskette, a hard disk, a randomaccess memory (RAM), a read-only memory (ROM), an erasable programmableread-only memory (EPROM or Flash memory), an optical fiber, a portablecompact disc read-only memory (CDROM), an optical storage device, amagnetic storage device, or any suitable combination of the foregoing.In the context of this document, a computer readable storage medium maybe any tangible medium that can contain or store a program for use by orin connection with an instruction execution system, apparatus, ordevice.

A computer readable signal medium may include a propagated data signalwith computer readable program code embodied therein, for example, in abaseband or as part of a carrier wave. Such a propagated signal may takeany of a variety of forms, including, but not limited to,electro-magnetic, optical, or any suitable combination thereof. Acomputer readable signal medium may be any computer readable medium thatis not a computer readable storage medium and that can communicate,propagate, or transport a program for use by or in connection with aninstruction execution system, apparatus, or device.

Computer code embodied on a computer readable medium may be transmittedusing any appropriate medium, including;but not limited to wireless,wireline, optical fiber cable, radio frequency (RF), etc., or anysuitable combination thereof.

Computer program code for carrying out operations for aspects of thepresent invention may be written in any combination of one or moreprogramming languages, including an object oriented programming languagesuch as Java™, Smalltalk™, C++, or the like, and conventional proceduralprogramming languages, such as the “C” programming language or similarprogramming languages. The program code may execute entirely on theuser's computer, partly on the user's computer, as a stand-alonesoftware package, partly on the user's computer and partly on a remotecomputer, or entirely on the remote computer or server. In the latterscenario, the remote computer may be connected to the user's computerthrough any type of network, including a local area network (LAN) or awide area network (WAN), or the connection may be made to an externalcomputer (for example, through the Internet using an Internet ServiceProvider).

Aspects of the present invention are described below with reference toflowchart illustrations and/or block diagrams of methods, apparatus(systems) and computer program products according to the illustrativeembodiments of the invention. It will be understood that each block ofthe flowchart illustrations and/or block diagrams, and combinations ofblocks in the flowchart illustrations and/or block diagrams, can beimplemented by computer program instructions. These computer programinstructions may be provided to a processor of a general purposecomputer, special purpose computer, or other programmable dataprocessing apparatus to produce a machine, such that the instructions,which execute via the processor of the computer or other programmabledata processing apparatus, create means for implementing thefunctions/acts specified in the flowchart and/or block diagram block orblocks.

These computer program instructions may also be stored in a computerreadable medium that can direct a computer, other programmable dataprocessing apparatus, or other devices to function in a particularmanner, such that the instructions stored in the computer readablemedium produce an article of manufacture including instructions thatimplement the function/act specified in the flowchart and/or blockdiagram block or blocks.

The computer program instructions may also be loaded onto a computer,other programmable data processing apparatus, or other devices to causea series of operational steps to be performed on the computer, otherprogrammable apparatus, or other devices to produce a computerimplemented process such that the instructions which execute on thecomputer or other programmable apparatus provide processes forimplementing the functions/acts specified in the flowchart and/or blockdiagram block or blocks.

Referring now to FIG. 4, this figure provides a flowchart outliningexample operations of a mechanism that provides a file system interfacefor point-to-point and collective operations. FIG. 4 depicts a highlevel operation performed in a data processing system for groupcommunications using a MULTI-PIPE synthetic file system in accordancewish an illustrative embodiment. As the operation begins, a masterapplication, which is requiring a mechanism for group communication,creates a multi-pipe synthetic file within the MULTI-PIPE synthetic filesystem (step 402). The master application then writes a header-controlblock to the multi-pipe synthetic file in MULTI-PIPE synthetic filesystem indicating how the multi-pipe synthetic file should perform andany restrictions for the other applications employed in the groupcommunications (step 404). Once the master application sends the controlmessage, any other applications that are participating in the groupcommunications open the same multi-pipe synthetic file (step 406). Eachof the other applications opens the same multi-pipe synthetic file inthe MULTI-PIPE synthetic file system, each multi-pipe limited to onlybeing used in the mode directed by the master application and is notable to send any control messages. The MULTI-PIPE synthetic file systemthen signals a MULTI-PIPE file system module in an operating system ofthe requested multi-pipe operation (step 408). The MULTI-PIPE filesystem module then implements the multi-pipe operation as identified bythe request from the master application (step 410), with the operationterminating thereafter. The mode that the other applications open themulti-pipe synthetic file in is dependent on the multi-pipe operationrequested by the master application.

The flowchart and block diagrams in the figures illustrate thearchitecture, functionality, and operation of possible implementationsof systems, methods and computer program products according to variousembodiments of the present invention. In this regard, each block in theflowchart or block diagrams may represent a module, segment, or portionof code, which comprises one or more executable instructions forimplementing the specified logical function(s). It should also be notedthat, in some alternative implementations, the functions noted in theblock may occur out of the order noted in the figures. For example, twoblocks shown in succession may, in fact, be executed substantiallyconcurrently, or the blocks may sometimes be executed in the reverseorder, depending upon the functionality involved. It will also be notedthat each block of the block diagrams and/or flowchart illustration, andcombinations of blocks in the block diagrams and/or flowchartillustration, can be implemented by special purpose hardware-basedsystems that perform the specified functions or acts, or combinations ofspecial purpose hardware and computer instructions.

Thus, the illustrative embodiments provide mechanisms for a multi-pipemechanism which builds upon the familiar syntax of pipes but providesfeatures and functions to better support emerging scale-out computingenvironments and applications. Similar to a pipe, the mechanism may beprimarily accessed purely through the file system namespace using onlypre-existing file system operations. In order to accomplish this, themechanism is implemented as a synthetic file system that does not useany backing storage like a typical file system.

As noted above, it should be appreciated that the illustrativeembodiments may take the form of an entirely hardware embodiment, anentirely software embodiment or an embodiment containing both hardwareand software elements. In one example embodiment, the mechanisms of theillustrative embodiments are implemented in software or program code,which includes but is not limited to firmware, resident software,microcode, etc.

A data processing system suitable for storing and/or executing programcode will include at least one processor coupled directly or indirectlyto memory elements through a system bus. The memory elements can includelocal memory employed during actual execution of the program code, bulkstorage, and cache memories which provide temporary storage of at leastsome program code in order to reduce the number of times code must beretrieved from bulk storage during execution.

Input/output or I/O devices (including but not limited to keyboards,displays, pointing devices, etc.) can be coupled to the system eitherdirectly or through intervening I/O controllers. Network adapters mayalso be coupled to the system to enable the data processing system tobecome coupled to other data processing systems or remote printers orstorage devices through intervening private or public networks. Modems,cable modems and Ethernet cards arc just a few of the currentlyavailable types of network adapters.

The description of the present invention has been presented for purposesof illustration and description, and is not intended to be exhaustive orlimited to the invention in the form disclosed. Many modifications andvariations will be apparent to those of ordinary skill in the art. Theembodiment was chosen and described in order to best explain theprinciples of the invention, the practical application, and to enableothers of ordinary skill in the art to understand the invention forvarious embodiments with various modifications as are suited to theparticular use contemplated.

1. A method, in a data processing system, for group communications usinga MULTI-PIPE synthetic file system, the method comprising: creating, bya master application in the data processing system, a multi-pipesynthetic file in a plurality of multi-pipe synthetic files in theMULTI-PIPE synthetic file system, wherein the master applicationindicates a multi-pipe operation to be performed; writing, by the masterapplication, a header-control block to the multi-pipe synthetic filespecifying at least one of a multi-pipe synthetic file system name, amessage type, a message size, a specific destination, or a specificationof the multi-pipe operation by writing to a specific offset; opening, byat least one other application in the plurality of applicationsparticipating in the group communications, the multi-pipe synthetic filein the MULTI-PIPE synthetic file system; signaling, by the MULTI-PIPEsynthetic file system, a MULTI-PIPE file system module in an operatingsystem of the multi-pipe operation; and implementing, by the MULTI-PIPEfile system module, the multi-pipe operation as identified by the masterapplication, wherein the master application and the at least one otherapplication in the group communication either read or write operationmessages to the multi-pipe synthetic file, wherein the messages aresignaled to the MULTI-PIPE files system module, and wherein theMULTI-PIPE synthetic file system module performs an appropriate actionbased on the mode identified by the master application.
 2. The method ofclaim 1, wherein the multi-pipe synthetic file opened by the at leastone other application is limited to only being used in the mode directedby the master application and wherein the at least one other applicationis not able to send any control messages.
 3. The method of claim 1,wherein the mode that the at least one other applications open themulti-pipe synthetic file in is dependent on the multi-pipe operationrequested by the master application.
 4. The method of claim 1, whereinthe MULTI-PIPE file system module is implemented as at least one of userspace file servers, embedded within the operating system itself asbuilt-in file systems, or a set of dynamically loaded modules.
 5. Themethod of claim 1, where the MULTI-PIPE synthetic file system isconstructed to allow allocation of new instances of the plurality ofmulti-pipe synthetic files via user action, either by leveragingexisting file-system interfaces or by using a synthetic control filewhich the plurality of applications may send commands to in order toallocate new instances of the plurality of multi-pipe synthetic files.6. The method of claim 1, wherein any application writing a message witha header-control block is directed to a specific enumerated reader queuewhere it will be received by a specific application when read from themulti-pipe file.
 7. The method of claim 1, wherein the masterapplication writing a broadcast message to the multi-pipe synthetic filetriggers a copy of the broadcast message to be delivered to allapplications in the group communications reading from the multi-pipesynthetic file by encoding a broadcast flag in the header-control block,wherein the master application writing the broadcast message which islonger than an atomic I/O buffer size of the multi-pipe synthetic fileis delivered using the header-control block with the message sizespecifying the total size of the broadcast message, and wherein themaster application writes the broadcast message which is longer than theatomic I/O buffer size of the multi-pipe synthetic file as a contiguousunit to at least one other application.
 8. The method of claim 1, wheredifferent ones of the at least one other application are isolated fromone another by the MULTI-PIPE synthetic file system enabling applicationappropriate multiplexing without the limitations of native file systemI/O multiplexing of the operating system and wherein, in non-enumeratedmulti-pipe synthetic files, individual ones of the at least one otherapplication reading from the multi-pipe synthetic file receive completemessages in a round robin fashion from the master application withoutfragment message intermixing.
 9. The method of claim 1, where the masterapplication changes the multi-pipe synthetic file system name of themulti-pipe synthetic file by writing to the header-control block of themulti-pipe synthetic file and wherein the master application clears thespecification of the multi-pipe operation of the multi-pipe syntheticfile by writing to the header-control block of the multi-pipe syntheticfile.
 10. The method of claim 1, wherein: all of the at least one otherapplication opening the multi-pipe synthetic file are blocked until afirst predetermined number of the at least one other application areblocked as specified by the master application in the header-controlblock written to the multi-pipe synthetic file by the masterapplication, all of the at least one other application reading themulti-pipe synthetic file are blocked until a second predeterminednumber of the at least one other application reading the multi-pipesynthetic file are blocked as specified by the master application in theheader-control block written to the multi-pipe synthetic file by themaster application, all of the at least one other application writingthe multi-pipe synthetic file are blocked until a third predeterminednumber of the at least one other application writing the multi-pipesynthetic file are blocked as specified by the master application in theheader-control block written to the multi-pipe synthetic file by themaster application, the master application writing a control message tothe multi-pipe file synthetic file is blocked until a fourthpredetermined number of the at least one other application have closedthe multi-pipe synthetic file as specified by the master application inthe header-control block written to the multi-pipe synthetic file by themaster application, and by the master application writes a reductioncontrol message to the multi-pipe synthetic file, a subsequent read onthe multi-pipe synthetic file by the master application will block untilall of the at least one other applications which have opened themulti-pipe synthetic file for writing to the multi-pipe synthetic filewrite a value to the multi-pipe synthetic file forming a set of valuesand the MULTI-PIPE file system module reduces the set of values andreturns a result of the reduction to the master application and whereinall of the at least one other applications receive the result of thereduction from the MULTI-PIPE file system module. 11-20. (canceled)